package com.you.member.dal.dao;

import org.springframework.orm.ibatis.support.SqlMapClientDaoSupport;

import com.you.member.dal.dao.dataobject.MemberDO;

/**
 * @author yunpeng.jiangyp
 */
public class MemberDAO extends SqlMapClientDaoSupport {

	public MemberDO find(Long id) {
		return (MemberDO) super.getSqlMapClientTemplate().queryForObject(
				"MS-SELECT-MEMBER-BY-PK", id);
	}

	public MemberDO findByEmail(String email) {
		return (MemberDO) super.getSqlMapClientTemplate().queryForObject(
				"MS-SELECT-MEMBER-BY-EMAIL", email);
	}

}
